Ext.onReady(function(){

    new Ext.Toolbar({
       renderTo: layout_menu,
       defaults:{ cls:'layout_menu_item' },
       items: [{
           text: 'Usuarios',
           handler: function(){
               //window.location = '/login/logout';
           },
           menu:{
               items: [{
                   text: 'Crear',
                   handler: function(){
                       window.location = '/usuario/crear';
                   }
               },{
                   text: 'Editar',
                   handler: function(){
                       window.location = '/usuario/editar';
                   }
               },{
                   text: 'Eliminar',
                   handler: function(){
                       //window.location = '/login/logout';
                   }
               },{
                   text: 'Buscar',
                   handler: function(){
                       window.location = '/usuario/buscar';
                   }
               }]
           }
       },{
           xtype: 'tbseparator'
       },{
           text: 'Profesores',
           handler: function(){
               //window.location = '/login/logout';
           },
           menu:{
               items: [{
                   text: 'Agregar',
                   handler: function(){
                       window.location = '/profesor/agregar';
                   }
               },{
                   text: 'Editar',
                   handler: function(){
                       window.location = '/profesor/editar';
                   }
               },{
                   text: 'Eliminar',
                   handler: function(){
                       //window.location = '/login/logout';
                   }
               },{
                   text: 'Buscar',
                   handler: function(){
                       window.location = '/profesor/buscar';
                   }
               }]
           }
       },{
           xtype: 'tbseparator'
       },{
           text: 'Tarjetas',
           handler: function(){
               //window.location = '';
           },
           menu:{
               items: [{
                   text: 'Generar',
                   handler: function(){
                       window.location = '/tarjeta/generar';
                   }
               },{
                   text: 'Reimprimir',
                   handler: function(){
                       window.location = '/tarjeta/reimprimir';
                   }
               }]
           }
       },{
           xtype: 'tbseparator'
       },{
           text: 'Reportes',
           handler: function(){
               //window.location = '/login/logout';
           },
           menu:{
               items: [{
                   text: 'Liquidación',
                   handler: function(){
                       window.location = '/reporte/liquidaciones';
                   }
               },{
                   text: 'Marcaciones',
                   handler: function(){
                       window.location = '/reporte/marcaciones';
                   }
               },{
                   text: 'Profesores',
                   handler: function(){
                       window.location = '/reporte/profesores';
                   }
               }]
           }
       },{
           xtype: 'tbseparator'
       },{
           text: 'Horarios',
           handler: function(){
               //window.location = '/login/logout';
           },
           menu:{
               items: [{
                   text: 'Crear',
                   handler: function(){
                      window.location = '/horario/crear';
                   }
               },{
                   text: 'Asociar',
                   handler: function(){
                       window.location = '/horario/asociar';
                   }
               },{
                   text: 'Visualizar',
                   handler: function(){
                       window.location = '/horario/visualizar';
                   }
               }]
           }
       },{
           xtype: 'tbfill'
       },{
           text: 'Salir',
           handler: function(){
               window.location = '/login/logout';
           }
       }]

    });

    Ext.get('layout_footer').dom.innerHTML =
        '<b>Desarrollado por LED.</b>'
    ;

})


